#ifndef VPDECODEAUDIOTHREAD_H
#define VPDECODEAUDIOTHREAD_H

#include <VpFrameQueue.h>
#include <VpPacketQueue.h>
extern "C"
{
#include <libavcodec/avcodec.h>

}
#define MAX_ADUIO_FRAME_NUM 9
class VpDecodeAudioThread
{

private:
    bool               m_stop;
    mutex              m_mutex;
    condition_variable m_cond;
public:
                VpDecodeAudioThread();
    bool        start              (AVCodecContext *codec_ctx, VpPacketQueue *audio_pkt_queue, VpFrameQueue *audio_fme_queue);
    void        stop               ();
    static void work               (VpDecodeAudioThread* vp_decode_audio_th, AVCodecContext *codec_ctx, VpPacketQueue *audio_pkt_queue, VpFrameQueue *audio_fme_queue);
};

#endif // VPDECODEAUDIOTHREAD_H
